package com.game.dao.user.dongfu;

import com.coment.po.UserDongFu;
import org.springframework.data.mongodb.repository.MongoRepository;


public interface UserDongFuDao extends MongoRepository<UserDongFu, Integer> {

    default UserDongFu findOrCreat(Integer userInfoId){
        return findById(userInfoId).orElseGet(() -> save(new UserDongFu(userInfoId,30003)));
    }
}
